<?php defined('IN_IA') or exit('Access Denied');?><?php  include $this->template('common/header', TEMPLATE_INCLUDEPATH);?>
<style>
.field label{float:left;margin:0 !important; width:140px;}
/*重定义bootstrap样式*/
select, textarea, input[type="text"], input[type="password"], input[type="datetime"], input[type="datetime-local"], input[type="date"], input[type="month"], input[type="time"], input[type="week"], input[type="number"], input[type="email"], input[type="url"], input[type="search"], input[type="tel"], input[type="color"], .uneditable-input{width:100%; margin-bottom:0; box-sizing:border-box; -webkit-box-sizing:border-box; -moz-box-sizing:border-box;}
input[type="text"], input[type="password"], input[type="datetime"], input[type="datetime-local"], input[type="date"], input[type="month"], input[type="time"], input[type="week"], input[type="number"], input[type="email"], input[type="url"], input[type="search"], input[type="tel"], input[type="color"], .uneditable-input{height:30px;}
.input-append, .input-prepend{width:100%; margin-bottom:0;}
select{padding:0 5px; line-height:28px; -webkit-appearance:button;}
.checkbox.inline{margin-top:0;}
.checkbox.inline + .checkbox.inline {margin-left:0;}
.checkbox input[type="checkbox"]{filter:alpha(opacity:0); opacity:0;}
.file{position:relative;}
.file input[type="file"]{position:absolute; top:0; left:0; width:100%; filter:alpha(opacity:0); opacity:0;}
.file button{width:100%; text-align:left;}
.tb{width:500px;}
</style>
<ul class="nav nav-tabs">
	<li class="active"><a href="<?php  echo $this->createWebUrl('profile', array('from_user' => $_GPC['from_user']));?>">编辑用户资料</a></li>
	<li><a href="<?php  echo $this->createWebUrl('fans');?>">用户列表</a></li>
</ul>
<div class="main">
<form action="" class="form-horizontal form" method="post" enctype="multipart/form-data">
<input type="hidden" name="from_user" value="<?php  echo $from_user;?>" />
	<h4>基本资料</h4>
	<table class="tb">
		<tr>
			<th><label for="">昵称</label></th>
			<td><?php  echo tpl_fans_form('nickname',$profile['nickname'] );?></td>
		</tr>
		<tr>
			<th><label for="">真实姓名</label></th>
			<td><?php  echo tpl_fans_form('realname',$profile['realname'] );?></td>
		</tr>
        
		<tr>
			<th><label for="">角色</label></th>
			<td>
                    <select name="grade">
                            <option value="">请选择</option>
                            <option value="0" <?php  if($profile['grade']==0 ) { ?> selected <?php  } ?>>普通关注者</option>
                            <option value="1" <?php  if($profile['grade']==1 ) { ?> selected <?php  } ?>>厨师</option>
                            <option value="2" <?php  if($profile['grade']==2 ) { ?> selected <?php  } ?>>名店</option>
                        </select>
                                        
			</td>
		</tr>
                
		<tr>
			<th><label for="">地区</label></th>
			<td>
				<?php  echo tpl_fans_form('reside',array('resideprovince' => $profile['resideprovince'], 'residecity' => $profile['residecity'], 'residedist' => $profile['residedist']));?>
			</td>
		</tr>
		<tr>
			<th><label for="">公司名称</label></th>
			<td><?php  echo tpl_fans_form('company',$profile['company']);?></td>
		</tr>        
		<tr>
			<th><label for="">详细地址</label></th>
			<td><?php  echo tpl_fans_form('address',$profile['address']);?></td>
		</tr>
		<tr>
			<th><label for="">手机</label></th>
			<td><?php  echo tpl_fans_form('mobile',$profile['mobile']);?></td>
		</tr>
		<tr>
			<th><label for="">QQ</label></th>
			<td><?php  echo tpl_fans_form('qq',$profile['qq']);?></td>
		</tr>
		<tr>
			<th><label for="">Email</label></th>
			<td><?php  echo tpl_fans_form('email',$profile['email']);?></td>
		</tr>
	</table>

	<table class="tb">
		<tr>
			<th></th>
			<td>
				<button type="submit" class="btn btn-primary span3" name="submit" value="提交">提交</button>
				<input type="hidden" name="token" value="<?php  echo $_W['token'];?>" />
			</td>
		</tr>
	</table>
</form>
</div>
<?php  include $this->template('common/footer', TEMPLATE_INCLUDEPATH);?>
